package com.czmh.etc.onlinepubsys.entity.mingchuang;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

import java.util.Date;

@Setter@Getter
@AllArgsConstructor
@NoArgsConstructor
@TableName("mingchuang_exchangecode")
public class ExchangeCode {
    @TableId
    private String id;

    @TableField("dv_id")
    private String dvId; //设备ID

    @TableField("dv_name")
    private String dvName;

    @TableField("dv_amount")
    private Integer dvAmount;

    @TableField("code")
    private String code; //代码

    @TableField("createTime")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime; //创建时间

    @TableField("exchangeTime")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date exchangeTime; //兑换时间

    @TableField("user_id")
    private String userId; //兑换人

    @TableField("state")
    private Integer state = 0; //0-未使用 1-已使用
}
